﻿using PetaPoco;
using PmSoft;
using PmSoft.Caching;
using System.ComponentModel;

namespace Modules.Person;

/// <summary>
/// 人员证书专业
///</summary>
[TableName("person_certificate_speciality")]
[Description("人员证书专业")]
[PrimaryKey("id", AutoIncrement = false)]
[CacheSetting(true, PropertyNamesOfArea = "CetificteId")]
[Serializable]
public class PersonCertificateSpeciality : IEntity
{
    /// <summary>
    /// 主键
    ///</summary>
    [Column("id")]
    public string Id { get; set; }

    /// <summary>
    /// 证书id
    ///</summary>
    [Column("cetificte_id")]
    public string CetificteId { get; set; }

    /// <summary>
    /// 注册专业编号
    ///</summary>
    [Column("code")]
    public string Code { get; set; }

    /// <summary>
    /// 注册专业名称
    ///</summary>
    [Column("speciality_name")]
    public string SpecialityName { get; set; }

    /// <summary>
    /// 注册专业起始日期
    ///</summary>
    [Column("start_date")]
    public DateTime? StartDate { get; set; }

    /// <summary>
    /// 注册专业截至日期
    ///</summary>
    [Column("end_date")]
    public DateTime? EndDate { get; set; }

    #region IEntity 成员

    [Ignore]
    object IEntity.EntityId { get { return this.Id; } }

    #endregion IEntity 成员
}